package cn.tedu.salary.controller;

import cn.tedu.salary.pojo.dto.SalaryQuery;
import cn.tedu.salary.pojo.vo.SalaryVO;
import cn.tedu.salary.service.SalaryService;
import cn.tedu.salary.util.PageBen;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;


@Slf4j
@RestController
@RequestMapping("/v1/salary/")
public class SalaryController {

    @Autowired
    private SalaryService salaryService;

    @PostMapping("/page")
    public PageBen<SalaryVO> queryPage(@RequestBody SalaryQuery salaryQuery){
        return salaryService.queryPage(salaryQuery);
    }

}
